<?php

namespace common\models\datas;

use Yii;

/**
 * This is the model class for table "{{%cards}}".
 *
 * @property integer $id
 * @property string $card_no
 * @property string $v_code
 * @property integer $status
 */
class Cards extends \common\components\bases\BaseModel
{
    /**
     * @inheritdoc
     */
    public static function tableName()
    {
        return '{{%cards}}';
    }

    /**
     * @inheritdoc
     */
    public function rules()
    {
        return [
            [['status'], 'integer'],
            [['card_no'], 'string', 'max' => 50],
            [['v_code'], 'string', 'max' => 60],
        ];
    }

    /**
     * @inheritdoc
     */
    public function attributeLabels()
    {
        return [
            'id' => Yii::t('common', '编号'),
            'card_no' => Yii::t('common', '卡号'),
            'v_code' => Yii::t('common', '激活码'),
            'status' => Yii::t('common', '状态 0:默认未领用 1:已领用'),
        ];
    }
}
